<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../vue.js"></script>
</head>

<body>
    <div id="app">
        <!-- lazy 失去焦点后才开始收集数据 -->
        <input type="text" v-model.number.lazy="score">
        <div>
            <p v-if="score>90">成绩是优秀</p>
            <p v-else-if="score>70">成绩是一般</p>
            <p v-else-if="score>50">成绩是差等</p>
            <p v-else>成绩是垃圾</p>
        </div>
    </div>
    <script>
        const vm = new Vue({
            el: '#app',
            data() {
                return {
                    score: null //score 是分数的意思 
                }
            }
        })
    </script>
</body>

</html>